/*
 * @Author: malgee
 * @Date: 2025-04-23 15:20:54
 * @LastEditors: maling
 * @LastEditTime: 2025-04-24 13:50:20
 * @FilePath: /vue3-ts-cms/src/service/login/login.ts
 * @Description: 
 * 
 */
import axiosHttp from "../index";
import { IAccount } from "./types";

export function fetchAccountLogin(data: IAccount) {
  return axiosHttp.post({
    url: '/login',
    data
  })
}

export function fetchUserInfo(id: string) {
  return axiosHttp.get({
    url: `/user/${id}`
  })
}

export function fetchUserMenusById(id: string) {
  return axiosHttp.get({
    url: `/role/${id}/menus`
  })
}